﻿namespace Labthink.PCSoft.UniversalHost4.Model.Setting
{
    /// <summary>
    /// 串口配置
    /// </summary>
    public class ComInfo
    {
        /// <summary>
        /// COM 口
        /// </summary>
        public string PortName { get; set; } = "COM1";

        /// <summary>
        /// 波特率
        /// </summary>
        public int BaudRate { get; set; } = 96100;

        /// <summary>
        /// 数据位
        /// </summary>
        public int DataBits { get; set; } = 8;

        /// <summary>
        /// 校验位
        /// </summary>
        public string Parity { get; set; } = "None";

        /// <summary>
        /// 停止位
        /// </summary>

        public int StopBits { get; set; } = 1;

        /// <summary>
        /// 读取超时时间
        /// </summary>
        public int ReadTimeout { get; set; }

        /// <summary>
        /// 是否保存串口数据
        /// </summary>
        public bool SaveComData { get; set; }
    }
}
